package routers

import (
	beego "github.com/beego/beego/v2/server/web"
	"website/controllers"
)

func init() {
	beego.Router("/", &controllers.MainController{})
	beego.Router("/user/register", &controllers.UserController{}, "post:Register")
	beego.Router("/user/login", &controllers.UserController{}, "post:Login")
	beego.Router("/news/add", &controllers.NewsController{}, "post:NewsAdd")
	beego.Router("/news/list", &controllers.NewsController{}, "post:NewsList")
	beego.Router("/news/del", &controllers.NewsController{}, "post:NewsDel")
}
